<!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>类的静态成员.html</title>
</head>

<body>
    <script>
        // function Phone(){

        // }

        // Phone.name = '手机';
        // Phone.chanage = function(){
        //     console.log("我可以改变世界");
        // }

        // Phone.prototype.size = 'S.sinch';

        // let nokai = new Phone();
        // console.log(nokai.name);
        // nokai.chanage();

        class Phone {
            //静态属性
            static name = '手机';
            static change() {
                console.log("我可以改变世界");
            }
        }

        let nokai = new Phone();
        console.log(nokai.name);
        console.log(Phone.name);
    </script>

</body>

</html>